package LuoGu.模拟与高精度.乒乓球;

import java.util.Scanner;
public class Main {
    static String temp = "";
    public static void main(String[] args) {
        //Scanner s = new Scanner(new BufferedInputStream(System.in));
        Scanner s = new Scanner(System.in);
        while(temp.contains("E")==false) temp+=s.next();
        temp = temp.substring(0,temp.indexOf("E"));
        e();
        t();
    }

    public static void e(){
        int a = 0;
        int b = 0;
        for(int i = 0;i<temp.length();i++){
            if(temp.charAt(i)=='W') a++;
            else b++;
            if((a>=11||b>=11)&&(Math.abs(a-b)>=2)){
                System.out.println(a+":"+b);
                a=0;
                b=0;
            }
        }
        System.out.println(a+":"+b);
        System.out.println();
    }

    public static void t(){
        int a = 0;
        int b = 0;
        for(int i = 0;i<temp.length();i++){
            if(temp.charAt(i)=='W') a++;
            else b++;
            if((a>=21||b>=21)&&(Math.abs(a-b)>=2)){
                System.out.println(a+":"+b);
                a=0;
                b=0;
            }
        }
        System.out.print(a+":"+b);
    }
}
